<template>
<div class="video-bd">
  <div class="item" :key="index" v-for="(item,index) of videoList">
    <div class="cover">
      <img :src="item.coverUrl" alt="">
      <div class="play">
        <i class="iconfont icon-icon_play"></i>
      </div>
    </div>
    <span>{{item.title}}</span>
  </div>
</div>
</template>

<script>
export default {
  name: "HomeMainVideoBD",
  data(){
    return{
      videoList:[
        {
          coverUrl:'https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/e74c4ff741bcdfc5b28a48a43e4edc6d.jpg?thumb=1&w=296&h=180&f=webp&q=90',
          title:'2021年春季新品发布会第一场'
        },
        {
          coverUrl:'https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/101b19aca4bb489bcef0f503e44ec866.jpg?thumb=1&w=296&h=180&f=webp&q=90',
          title:'Redmi 10X系列发布会'
        },
        {
          coverUrl:'https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/96563e75833ba4563bd469dd28203b09.jpg?thumb=1&w=296&h=180&f=webp&q=90',
          title:'小米10 青春版 发布会'
        },
        {
          coverUrl:'https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/2fd26bb99b723337a2f8eaba84f7d5bb.jpg?thumb=1&w=296&h=180&f=webp&q=90',
          title:'小米10 8K手机拍大片'
        },
      ]
    }
  }
}
</script>

<style scoped lang="scss">
.video-bd{
  height: 285px;
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  .item{
    width: 296px;
    height: 100%;
    background: white;
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 14px;
    transition: all 0.5s;
    &:hover {
      box-shadow: 0 5px 30px 0 #bdbdbd;
      transform: translateY(-5px);
      transition: all 0.5s;
    }
    .cover{
      height: 180px;
      width: 100%;
      background: #c7c7c7;
      position: relative;
      margin-bottom: 28px;
      transition: all 0.4s;
      &:hover{
        .play{
          border: 2px solid #FF6700;
          background: #FF6700;
          transition: all 0.4s;
        }
      }
      img{
        width: 100%;
        height: 100%;
      }
      .play{
        position: absolute;
        left: 20px;
        bottom: 10px;
        width: 36px;
        height: 24px;
        border-radius: 12px;
        border: 2px solid white;
        background-color: rgba(0,0,0,.6);
        display: flex;
        align-items: center;
        justify-content: center;
        i{
          color: white;
          font-size: 10px;
        }
      }
    }
    span{
      font-size: 14px;
      color: #333333;
    }
  }
}
</style>